package cn.qqncn.controller;

import cn.qqncn.client.EmailClient;
import cn.qqncn.entity.Capsule;
import cn.qqncn.service.CapsuleService;
import cn.qqncn.utils.R;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.HashMap;
import java.util.Map;

/**
 * @author zkw
 * @Description 胶囊 控制层
 * @createTime 2021年05月08日 16:04:00
 */
@RestController
public class CapsuleController {
    @Autowired
    CapsuleService capsuleService;

    @Autowired
    EmailClient emailClient;

    @PostMapping("/addCapsule")
    public R addCapsule(@RequestBody Capsule capsule){
        boolean b = capsuleService.addCapsule(capsule);
        System.out.println(capsule);
        return R.ok();
    }

    @GetMapping("get")
    public R get(){
        return R.ok();
    }




}
